package com.iclippi.server.model;

import java.util.Properties;

import javax.jdo.JDOHelper;
import javax.jdo.PersistenceManagerFactory;


public final class PMF {
	private static PersistenceManagerFactory pmfInstance;

    private PMF() {}

    public static PersistenceManagerFactory get() {
    	if (pmfInstance==null) pmfInstance = JDOHelper.getPersistenceManagerFactory("transactions-optional");
        return pmfInstance;
    }
    
    public static void setProperties(Properties properties){
    	pmfInstance=JDOHelper.getPersistenceManagerFactory(properties);
    }

}
